#include <bits/stdc++.h>

#define in read()
#define rep(i, x, y) for(int i = (x); i <= (y); i++)
#define per(i, x, y) for(int i = (x); i >= (y); i--)

using namespace std;

int read() {
    int x = 0; bool f = 0; char ch = getchar(); while(!isdigit(ch)) f |= ch == '-',ch = getchar();
    while(isdigit(ch)) x = x * 10 + (ch ^ 48),ch = getchar(); return f ? -x : x;
}

const int S = (1 << 14) + 10;
const int N = 110;
const int inf = 0x3f3f3f3f;

int f[S][N],g[S][N],n,m,ans,U,dis1[S][17],dis2[S][N];
struct tele { int x, y; } a[N];
struct task { int x, y, t; } t[N];
void getmn(int &x,int y) { x = x < y ? x : y; }
void getmx(int &x,int y) { x = x < y ? y : x; }

int main() {
#ifndef ONLINE_JUDGE
    freopen("1.in","r",stdin);
#endif
    n = in, m = in, U = (1 << n) - 1;
	rep(i, 0, n - 1) a[i].x = in, a[i].y = in;
	rep(i, 1, m) t[i].x = in, t[i].y = in, t[i].t = in;
	sort(t + 1, t + m + 1, [](task a,task b) { return a.t < b.t; });
	rep(s, 0, U) rep(j, 0, n - 1) dis1[s][j] = inf;
	rep(s, 0, U) rep(j, 1, m) dis2[s][j] = inf;
	rep(i, 0, n - 1) {
		rep(j, 0, n - 1) dis1[1 << j][i] = abs(a[j].x - a[i].x) + abs(a[j].y - a[i].y);
		rep(s, 1, U) {
			int lb = s & -s; if(s == lb) continue;
			dis1[s][i] = min(dis1[s ^ lb][i], dis1[lb][i]);
		}
	}
	rep(i, 1, m) {
		rep(j, 0, n - 1) dis2[1 << j][i] = abs(a[j].x - t[i].x) + abs(a[j].y - t[i].y);
		rep(s, 1, U) {
			int lb = s & -s; if(s == lb) continue;
			dis2[s][i] = min(dis2[s ^ lb][i], dis2[lb][i]);
		}
	}
	// ----- prework -----
	rep(s, 0, U) rep(i, 0, m) f[s][i] = inf,g[s][i] = -inf;
	rep(i, 0, n - 1) f[1 << i][0] = 0;
	rep(i, 1, m) g[0][i] = 1;
	rep(s, 0, U) {
		rep(i, 0, m) {
			rep(j, 0, n - 1)
				if(!(s >> j & 1))
					getmn(f[s | 1 << j][i], f[s][i] + dis1[s][j]);
			rep(j, 1, m)
				if(f[s][i] + dis2[s][j] <= t[j].t) getmx(g[s][j], i + 1);
		}
		rep(i, 1, m) {
			rep(j, i + 1, m) 
				if(t[i].t + min(abs(t[i].x - t[j].x) + abs(t[i].y - t[j].y), dis2[s][j]) <= t[j].t)
					getmx(g[s][j], g[s][i] + 1);
			rep(j, 0, n - 1)
				if(g[s][i] >= 0 && !(s >> j & 1))
					getmn(f[s | 1 << j][g[s][i]], t[i].t + min(dis1[s][j], abs(t[i].x - a[j].x) + abs(t[i].y - a[j].y)));
			getmx(ans, g[s][i]);
		}
	}
	cout << ans << endl; return 0;
}
